home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
VRML 2.0 Sourcebook (2nd Edition)
/
VRML 2.0 Sourcebook CD [md5 fed90f4f9c39d5a60d477058775c7e21].iso
/
book
/
mac
/
ch16
/
16fig05.wrl
< prev
next >
Wrap
Text File
|
1996-09-23
|
2KB
|
81 lines
#VRML V2.0 utf8
# The VRML 2.0 Sourcebook
# Copyright [1997] By
# Andrea L. Ames, David R. Nadeau, and John L. Moreland
Group {
children [
# A log
Transform {
translation 0.0 -0.4 0.0
rotation 0.0 0.0 1.0 -1.57
children Shape {
appearance Appearance {
material Material {
diffuseColor 0.5 0.3 0.0
}
}
geometry Cylinder {
height 2.9
radius 0.4
}
}
},
# A set of flames
DEF Flames Shape {
# No appearance, use emissive coloring
geometry IndexedFaceSet {
coord Coordinate {
point [
-0.7 0.0 0.0, -0.8 1.5 0.0, -1.0 0.0 0.0,
-0.5 0.0 0.01, -0.7 1.2 0.01, -0.9 0.0 0.01,
-0.1 0.0 0.0, -0.2 1.6 0.0, -0.4 0.0 0.0,
0.3 0.0 0.01, 0.2 1.0 0.01, 0.0 0.0 0.0,
]
}
coordIndex [
0, 1, 2, -1, 3, 4, 5, -1,
6, 7, 8, -1, 9, 10, 11, -1
]
solid FALSE
colorPerVertex TRUE
color Color {
color [
1.0 0.0 0.0, 1.0 0.5 0.0, 1.0 0.1 0.0,
0.8 0.0 0.0, 1.0 0.9 0.0, 1.0 0.0 0.0,
]
}
colorIndex [
3, 4, 5, 0, 0, 1, 2, 0,
3, 4, 5, 0, 0, 1, 2, 0
]
}
},
# Repeat the flames to make a roaring fire
Transform {
translation 0.8 0.0 0.02
scale 1.0 1.3 1.0
children USE Flames
},
Transform {
translation 1.1 0.0 0.04
scale 1.0 0.5 1.0
children USE Flames
},
Transform {
translation -0.3 0.0 0.06
scale 1.0 1.1 1.0
children USE Flames
},
Transform {
translation -0.1 0.0 0.08
scale 1.0 0.4 1.0
children USE Flames
},
Transform {
translation 0.8 0.0 0.10
scale 1.0 1.1 1.0
children USE Flames
}
]
}